<?
function showAdv($row, $file_path, $i = 0){
	switch($row["adv_type"]){
		case 1:
			if($i == 0){
				
			}else{
				?>
				<div style="height: 100px; overflow: hidden; width: 270px; border: solid 1px #f2f2f2; margin-bottom: 3px;" align="center">
					<img src="<?=$file_path?><?=$row["adv_picture"]?>" border="0"/>
				</div>
				<input type="file" name="picture_<?=$row["adv_id"]?>" class="form_control" />
				<?
			}
		break;
		case 2:
			if($i == 0){
				
			}else{
				?>
				<div style="height: 100px; overflow: hidden; width: 270px; border: solid 1px #f2f2f2; margin-bottom: 3px;" align="center">
					<script language="javascript">ShowFlash_swf('banner_<?=$row["adv_id"]?>', "<?=$file_path?><?=$row["adv_picture"]?>", 270, 100)</script>
				</div>
				<input type="file" name="picture_<?=$row["adv_id"]?>" class="form_control" />
				<?
			}
		break;
		case 3:
			if($i == 0){
				
			}else{
				?>
				<div style="height: 100px; overflow: hidden; width: 270px; border: solid 1px #f2f2f2; margin-bottom: 3px;" align="center">
					<textarea class="form_control" style="height: 100px; width: 270px;"><?=$row["adv_html"]?></textarea>
				</div>
				<div style="display: none;"><input type="file" name="picture_<?=$row["adv_id"]?>" class="form_control" /></div>
				<?
			}
		break;				
	}
}
?>